package com.stellar.circle.controller.admin.sChatRelationship;

import com.stellar.circle.controller.admin.sChatRelationship.vo.SChatRelationshipRequestVO;
import com.stellar.circle.controller.admin.sChatRelationship.vo.SChatRelationshipResponseVO;
import com.stellar.circle.domain.sChatRelationship.SChatRelationshipDomainService;

import com.stellar.web.core.bean.Result;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;
import java.util.List;

/**
 * 用户聊天关系控制器
 *
 * @author Jqchan
 * @version 1.0
 * @date 2025-06-12 21:21:20
 */
@RequestMapping("/api-admin/sChatRelationship")
@RestController("adminSChatRelationshipController")
@Slf4j
public class SChatRelationshipController {

    @Resource
    private SChatRelationshipDomainService sChatRelationshipDomainService;

    /**
     * 查询用户的聊天关系列表 - 待优化，使用分页
     */
    @GetMapping("/list/{userId}")
    public Result<List<SChatRelationshipResponseVO>> list(@PathVariable("userId") Long userId) {
        return Result.success(sChatRelationshipDomainService.list(userId));
    }
}